package com.ruoyi.system.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 优惠券对象 t_coupon
 * 
 * @author ruoyi
 * @date 2024-01-08
 */
public class TCoupon extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键id */
    private Long id;

    /** 优惠券名称 */
    @Excel(name = "优惠券名称")
    private String couponName;

    /** 优惠券面值 */
    @Excel(name = "优惠券面值")
    private Integer parValue;

    /** 优惠券地址 */
    @Excel(name = "优惠券地址")
    private String couponUrl;

    /** 是否启动 0 未启用  1启用 */
    @Excel(name = "是否启动 0 未启用  1启用")
    private Integer isEnabled;

    /** 优惠券有效期开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "优惠券有效期开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date startPeriodTime;

    /** 优惠券有效期结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "优惠券有效期结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date endPeriodTime;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setCouponName(String couponName) 
    {
        this.couponName = couponName;
    }

    public String getCouponName() 
    {
        return couponName;
    }
    public void setParValue(Integer parValue) 
    {
        this.parValue = parValue;
    }

    public Integer getParValue() 
    {
        return parValue;
    }
    public void setCouponUrl(String couponUrl) 
    {
        this.couponUrl = couponUrl;
    }

    public String getCouponUrl() 
    {
        return couponUrl;
    }
    public void setIsEnabled(Integer isEnabled) 
    {
        this.isEnabled = isEnabled;
    }

    public Integer getIsEnabled() 
    {
        return isEnabled;
    }
    public void setStartPeriodTime(Date startPeriodTime) 
    {
        this.startPeriodTime = startPeriodTime;
    }

    public Date getStartPeriodTime() 
    {
        return startPeriodTime;
    }
    public void setEndPeriodTime(Date endPeriodTime) 
    {
        this.endPeriodTime = endPeriodTime;
    }

    public Date getEndPeriodTime() 
    {
        return endPeriodTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("couponName", getCouponName())
            .append("parValue", getParValue())
            .append("couponUrl", getCouponUrl())
            .append("isEnabled", getIsEnabled())
            .append("startPeriodTime", getStartPeriodTime())
            .append("endPeriodTime", getEndPeriodTime())
            .append("updateTime", getUpdateTime())
            .append("updateBy", getUpdateBy())
            .append("createTime", getCreateTime())
            .append("createBy", getCreateBy())
            .toString();
    }
}
